package cn.hdustea.shopNavigation.ui.contract

import cn.hdustea.shopNavigation.entity.UserEntity
import com.hdustea.base.base.IBaseModel
import com.hdustea.base.base.IBasePresenter
import com.hdustea.base.base.IBaseView
import com.hdustea.base.net.BaseCallback

interface AccountContract {
    interface Presenter : IBasePresenter {

        fun login(username: String, password: String)

        fun register(username: String, password: String, phone: String)
    }

    interface View : IBaseView {

        fun loginSuccess(userEntity: UserEntity?)

    }

    interface Model : IBaseModel {

        fun login(username: String, password: String, callback: BaseCallback<UserEntity>)

        fun register(username: String, password: String, phone: String, callback: BaseCallback<Result<String>>)
    }
}